package com.atguigu.gulimall.member.service;

import com.atguigu.gulimall.member.exception.MemberException;
import com.atguigu.gulimall.member.vo.MemberUserLoginVo;
import com.atguigu.gulimall.member.vo.UserRegisterVo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.member.entity.MemberEntity;

import java.util.Map;

/**
 * 会员
 *
 * @author ShiJieLin
 * @email ShiJieLin@gmail.com
 * @date 2022-03-29 10:50:45
 */
public interface MemberService extends IService<MemberEntity> {

    PageUtils queryPage(Map<String, Object> params);

    /** 认证中心认证之后，用户注册保存用户信息
     * @param vo
     */
    void register(UserRegisterVo vo) throws MemberException;

    /** 用户登陆，验证用户能否登陆
     * @param vo
     * @return
     */
    MemberEntity login(MemberUserLoginVo vo);

    /** 用户使用微信登陆
     * @param accessTokenInfo 微信返回的
     * @return
     */
    MemberEntity login(String accessTokenInfo) throws Exception;
}

